/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package eventxmlparser;

import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlValue;
import org.simpleframework.xml.Attribute;
import org.simpleframework.xml.Element;

/**
 *
 * @author krist_000
 */
public class CloseByEvent {
    
    @Attribute
    private int radius;
    
    @Attribute
    private int tolerance;
    
    @Attribute(name = "time")
    private String timeTable;
    
    @Element(name = "AreaId")
    private String areaID;

    @XmlAttribute
    public int getRadius() {
        return radius;
    }

    public void setRadius(int radius) {
        this.radius = radius;
    }

    @XmlAttribute
    public int getTolerance() {
        return tolerance;
    }

    public void setTolerance(int tolerance) {
        this.tolerance = tolerance;
    }

    @XmlAttribute(name = "time")
    public String getTimeTable() {
        return timeTable;
    }

    public void setTimeTable(String timeTable) {
        this.timeTable = timeTable;
    }

    @XmlValue
    public String getAreaID() {
        return areaID;
    }

    public void setAreaID(String areaID) {
        this.areaID = areaID;
    }

    @Override
    public String toString() {
        return "CloseByEvent id " + areaID + " timetable " + timeTable + " radius " + radius + " tolerance " + tolerance + "\n";
    }
    
    
}
